-- @owner: z@wan005
-- @date: 2022/3/3
-- @testpoint: 自定义函数，timestamp类型调用和返回
@conn PrimaryDbBmode;
--step1:创建函数指定参数数据类型是year;expect:成功
drop function if exists f_timestamp_0017;
create or replace function f_timestamp_0017 (ts_timestamp timestamp) returns timestamp  as $$
        begin
                return (ts_timestamp);
        end;
$$ language plpgsql;
/

--step2:调用函数;expect:成功
call f_timestamp_0017('99-12-31 23:59:59.9999999');
call f_timestamp_0017('99991231235959');
call f_timestamp_0017(99991231235959::timestamp);
--step3:清理环境;expect:成功
drop function f_timestamp_0017(ts_timestamp timestamp);